home *** CD-ROM | disk | FTP | other *** search
/ Windows Expert / Windows Expert.iso / program / tpw_mmex.zip / MMPTYPES.PAS < prev    next >
Pascal/Delphi Source File  |  1991-12-18  |  7KB  |  156 lines

  1. {***********************************************************************}
  2. {                                                                       }
  3. {  Microsoft Multimedia Player Structures and Constants                 }
  4. {  Links to the mmp.dll in the Microsoft Multimedia Extensions          }
  5. {  Converted by Steve Milton @ ISOMEDIA, Inc. for use with              }
  6. {  Borland's Turbo Pascal for Windows                                   }
  7. {                                                                       }
  8. {  These units are provided as-is with no warranty.  Any damages to     }
  9. {  equipment, peripherals, software, or anything else is solely the     }
  10. {  responsibility of the user.                                          }
  11. {                                                                       }
  12. {  Microsoft Multimedia Extensions is a trademark of Microsoft, Corp.   }
  13. {  Turbo Pascal for Windows is a trademakr of Borland International     }
  14. {                                                                       }
  15. {***********************************************************************}
  16.  
  17. unit MMPTYPES;
  18.  
  19. INTERFACE
  20.  
  21. uses wintypes;
  22.  
  23. CONST
  24. {***************************************************************************
  25.  
  26.                           MMP error return values
  27.  
  28. ***************************************************************************}
  29.  
  30. MMPERR_NO_ERROR      =  0;        { no error                               }
  31. MMPERR_FATAL_ERROR   =  (-101);   { fatal error                            }
  32. MMPERR_STAGE_ERROR   =  (-102);   { error creating stage window            }
  33. MMPERR_FILE_VER      =  (-110);   { wrong file version                     }
  34. MMPERR_FILE_TYPE     =  (-111);   { not an MMP movie file                  }
  35. MMPERR_OPEN_ERROR    =  (-112);   { DOS error opening file                 }
  36. MMPERR_READ_ERROR    =  (-113);   { DOS read error on file                 }
  37. MMPERR_EOF_ERROR     =  (-115);   { unexpected end of file                 }
  38. MMPERR_REC_HEADER    =  (-116);   { invalid record header                  }
  39. MMPERR_CAST_ERROR    =  (-117);   { error reading cast                     }
  40. MMPERR_CAST_MAP_ERROR=  (-118);   { cast/bitmap mismatch                   }
  41. MMPERR_MEM_ALLOC     =  (-121);   { memory allocation error                }
  42. MMPERR_USER_ABORT    =  (-122);   { user canceled operation                }
  43. MMPERR_MMP_BUSY      =  (-412);   { re-entered from frame callback or      }
  44.                                         { other task with different ID    }
  45. MMPERR_BAD_PARM      =  (-426);   { bad parameters                         }
  46.  
  47. MMP_MOVEOK           =  1;        { boolean field definition               }
  48. SCRIPTCHANNEL        =  (-1);     { script channel action code             }
  49.  
  50. MMP_MAXERRORLENGTH   =  128;      { maximum length of error strings        }
  51.  
  52.  
  53. {***************************************************************************
  54.  
  55.                               MMP constants
  56.  
  57. ***************************************************************************}
  58.  
  59. { flags for wOptions parameter of mmpGoToFrame() function                 }
  60. MMP_FRAME_FIRST    =  1;
  61. MMP_FRAME_LAST        = $7FFF;
  62.  
  63. { messages passed to wMsg parameter of frame callback                     }
  64. MMP_HOOK_FRAME        = $0003;
  65. MMP_HOOK_SCRIPT       = $0004;
  66. MMP_HOOK_LOAD         = $0005;
  67.  
  68. { flags for nTempo parameter of mmpSetTempo() function                    }
  69. MMPTEMPO_SOUNDWAIT1  = (-121);
  70. MMPTEMPO_MOUSEWAIT   = (-128);
  71.  
  72. { animation status returned from mmpAnimate() and mmpAnimStatus() functions}
  73. MMP_TEMPO_WAIT       = 1;     { waiting to advance frame                    }
  74. MMP_ANIM_DRAW        = 2;     { drawing in progress                         }
  75. MMP_ANIM_DRAWN       = 3;     { frame drawn, frame callback not called      }
  76. MMP_SCRIPT_PROCESSED = 4;     { frame callback just executed                }
  77. MMP_FRAME_DONE       = 5;     { all processing for current frame done       }
  78. MMP_MOUSE_WAIT       = (-1);  { waiting for mouse click                     }
  79. MMP_DEVICE_WAIT      = (-2);  { waiting for device to finish                }
  80. MMP_ANIM_STOPPED     = (-3);  { animation is stopped                        }
  81.  
  82. { flags for nIndex parameter of mmpGetInfo() function                     }
  83. MMPINFO_LABELLIST  = (-6);    { label-list array                            }
  84. MMPINFO_LABELTEXT  = (-7);    { label-text block                            }
  85. MMPINFO_LABELCOUNT = (-8);    { count of label entries                      }
  86. MMPINFO_ACTIONLIST = (-9);    { action-list array                           }
  87. MMPINFO_ACTIONTEXT = (-10);   { action-text block                           }
  88. MMPINFO_ACTIONCOUNT= (-11);   { count of action entries                     }
  89.  
  90. { flags for wOptions parameter of mmpSetStage() and mmpGetStage() functions}
  91. MMP_STAGE_CENTER     = $1;     { centered in stage window                    }
  92. MMP_STAGE_OFFSET     = $2;     { offset to a fixed location                  }
  93. MMP_STAGE_BORDER     = $4;     { border is drawn around stage rect           }
  94. MMP_STAGE_FIXED      = $8;     { stage size isconstant between movies        }
  95.  
  96. { flags for wOptions parameter of mmpLoadFile() function                  }
  97. MMP_LOAD_REFERENCED  = $1;     { load if referenced from score               }
  98. MMP_LOAD_NOSTATIC    = $2;     { use system reserved colors                  }
  99. MMP_LOAD_ONDEMAND    = $8;     { load DIBs as they are used                  }
  100. MMP_LOAD_EXPANDDIBS  = $10;    { convert DIBs to RLE format at load time     }
  101. MMP_DRAW_FRAME       = $C000;  { draw frame                                  }
  102. MMP_ERASE_FRAME      = $2000;  { erase entire stage                          }
  103.  
  104.  
  105.  
  106. TYPE
  107. {***************************************************************************
  108.  
  109.                               MMP data types
  110.  
  111. ***************************************************************************}
  112.  
  113. { movie ID}
  114. MMPID = longint;
  115.  
  116. { movie information structure}
  117. LP_MMPINFO = ^MMPINFO;
  118. MMPINFO = record
  119.   dwFileVersion : LONGINT;
  120.   dwTotalFrames : LONGINT;
  121.   dwInitialFramesPerSecond : LONGINT;
  122.   wPixelDepth : WORD;
  123.   dwMovieExtentX : LONGINT;
  124.   dwMovieExtentY : LONGINT;
  125.   achFullMacName : array [0..32] of char;
  126. end;
  127. MMPMOVIEINFO = MMPINFO;
  128. LP_MMPMOVIEINFO = ^ MMPMOVIEINFO;
  129.  
  130. { label-list information structure}
  131. MMPLABEL = record
  132.   wFrameNum : WORD;
  133.   wTextOffset : WORD;
  134. end;
  135.  
  136. { action-list information structure}
  137. MMPACTION = record
  138.   bMenuItem : BYTE;
  139.   bActionCode : BYTE;
  140.   wTextOffset : WORD;
  141. end;
  142.  
  143.  
  144. TYPE
  145.   LP_RECT =         ^TRect;
  146.   LP_MMPFRAMEHOOK =     pointer;
  147.   LP_WORD =        ^WORD;
  148.  
  149.  
  150. IMPLEMENTATION
  151.  
  152.  
  153.  
  154. BEGIN
  155. END.
  156.